﻿@model IEnumerable<HR_ASP.ViewModel.PracownikViewModel>

@{
    ViewBag.Title = "Index";
}

<h2>Index</h2>

<p>
    @Html.ActionLink("Create New", "Create")
</p>
<table>
    <tr>
        <th>
            Identyfikator
        </th>
        <th>
            Imie
        </th>
        <th>
            Nazwisko
        </th>
        <th>
            Pesel
        </th>
        <th>
            Email
        </th>
        <th>
            Miasto
        </th>
        <th>
            Kod
        </th>
        <th>
            Ulica
        </th>
        <th>
            Numer
        </th>       
        <th></th>
    </tr>

@foreach (var item in Model) {
    <tr>
        <td>
            @Html.DisplayFor(modelItem => item.Identyfikator)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.Imie)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.Nazwisko)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.Pesel)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.Email)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.Miasto)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.Kod)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.Ulica)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.Numer)
        </td>       
        <td>
            @Html.ActionLink("Edit", "Edit", new { id=item.ID }) |
            @Html.ActionLink("Details", "Details", new { id=item.ID }) |
            @Html.ActionLink("Delete", "Delete", new { id=item.ID })
        </td>
    </tr>
}

</table>
